<%@ page import="com.lumm.model.Staff" %>
<!-- <%--
  Created by IntelliJ IDEA.
  User: qhzhy
  Date: 2018/9/10
  Time: 20:50
  To change this template use File | Settings | File Templates.
--%>-->
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ page isELIgnored="false" %>

<% Staff staff = (Staff) pageContext.getSession().getAttribute("staff");%>

<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>滴滴相亲后台管理<%=staff%>
    </title>
    <script src="/js/jquery.min.js"></script>
    <script src="/js/bootstrap.min.js"></script>
    <script src="/js/jquery-form.js"></script>
    <script>
        $(function () {
            $(".menu-item").click(function () {
                $(".menu-item").removeClass("menu-item-active");
                $(this).addClass("menu-item-active");
                var itmeObj = $(".menu-item").find("img");
                itmeObj.each(function () {
                    var items = $(this).attr("src");
                    items = items.replace("_grey.png", ".png");
                    items = items.replace(".png", "_grey.png")
                    $(this).attr("src", items);
                });
                var attrObj = $(this).find("img").attr("src");
                ;
                //attrObj = attrObj.replace("_grey.png", ".png");
                $(this).find("img").attr("src", attrObj);
            });
            $("#topAD").click(function () {
                $("#topA").toggleClass(" glyphicon-triangle-right");
                $("#topA").toggleClass(" glyphicon-triangle-bottom");
            });
            $("#topBD").click(function () {
                $("#topB").toggleClass(" glyphicon-triangle-right");
                $("#topB").toggleClass(" glyphicon-triangle-bottom");
            });
            $("#topCD").click(function () {
                $("#topC").toggleClass(" glyphicon-triangle-right");
                $("#topC").toggleClass(" glyphicon-triangle-bottom");
            });
            $(".toggle-btn").click(function () {
                $("#leftMeun").toggleClass("show");
                $("#rightContent").toggleClass("pd0px");
            })
        })
    </script>
    <!--[if lt IE 9]>
    <script src="/js/html5.js"></script>
    <script src="/js/respond.min.js"></script>
    <![endif]-->
    <link href="/css/bootstrap.min.css" rel="stylesheet"/>
    <link rel="stylesheet" type="text/css" href="/css/common.css"/>
    <link rel="stylesheet" type="text/css" href="/css/slide.css"/>
    <link rel="stylesheet" type="text/css" href="/css/bootstrap.min.css"/>
    <link rel="stylesheet" type="text/css" href="/css/flat-ui.min.css"/>
    <link rel="stylesheet" type="text/css" href="/css/jquery.nouislider.css"/>
    <link rel="stylesheet" type="text/css" href="/css/style-site.css"/>

    <!--====================================================-->

    <!--====================================================-->
</head>
<body>
<div id="wrap">
    <!-- 左侧菜单栏目块 -->
    <div class="leftMeun" id="leftMeun">

        <div id="clock" style="background-color: transparent">
            <%--<embed wmode="transparent" type="application/x-shockwave-flash"
                   pluginspage="http://www.macromedia.com/go/getflashplayer" allownetworking="internal"
                   allowscriptaccess="always" quality="high"
                   src="http://www.hebin.me/wp-content/uploads/2017/swf/clock.swf" width="160" height="100">
            <div>
                ${staff.type==0?"管理员:":"红娘:"}
                ${staff.userName}
                <span style="background-image: url('/images/icon_logout.gif')" class=""/></span>
            </div>--%>

            <h3 style="color: whitesmoke">滴滴相亲</h3>
            <div class="" style="width:100%;padding-right: 9px;color: white;display: block;text-align: right">
                后台管理系统
            </div>


            <div style="margin-top: 9px;padding-right: 12px;">
                <label style="color: #5bc0de">${staff.type==0?"管理员":"红娘"}: </label>
                <a style="margin-left: 6px">${staff.userName}</a>
                <a class="btn btn-primary btn-xs pull-right" href="/admin/logout">退出</a>
            </div>

        </div>


        <div class="menu-title">员工</div>
        <%
            if (staff.getType() == 0) {
        %>
        <div class="menu-item menu-item-active" href="#sour" aria-controls="sour" role="tab" data-toggle="tab">
            工作人员管理
        </div>
        <%
            }
        %>
        <div class="menu-item" href="#chan" aria-controls="chan" role="tab" data-toggle="tab">修改账户密码</div>
        <div class="menu-title">会员</div>
        <%
            if (staff.getType() == 0) {
        %>
        <div class="menu-item" href="#user" aria-controls="user" role="tab" data-toggle="tab">会员管理</div>
        <%
            }
        %>
        <div class="menu-item" href="#stud" aria-controls="stud" role="tab" data-toggle="tab">成果库</div>
        <%
            if (staff.getType() == 1) {
        %>
        <div class="menu-item menu-item-active" href="#sitt" aria-controls="sitt" role="tab" data-toggle="tab">姻缘簿</div>
        <%
            }
        %>

        <%
            if (staff.getType() == 0) {
        %>
        <div class="menu-title">商城</div>
        <div class="menu-item" href="#scho" aria-controls="scho" role="tab" data-toggle="tab">商城</div>
        <%
            }
        %>

        <div class="menu-title">活动</div>
        <div class="menu-item" href="#char" aria-controls="char" role="tab" data-toggle="tab">活动管理</div>
        <div class="menu-item"></div>


    </div>

    <!-- 右侧具体内容栏目 -->
    <div id="rightContent">
        <!-- Tab panes -->
        <div class="tab-content">

            <%
                if (staff.getType() == 0) {
            %>
            <!-- 员工管理 -->
            <%@ include file="/WEB-INF/pages/admin/divs/staffManageDiv.jsp" %>
            <%
                }
            %>

            <!-- 修改密码模块 -->
            <%@ include file="/WEB-INF/pages/admin/divs/changePasswordDiv.jsp" %>

            <%
                if (staff.getType() == 0) {
            %>
            <!--会员管理模块-->
            <%@ include file="/WEB-INF/pages/admin/divs/userManageDiv.jsp" %>
            <%
                }
            %>

            <!-- 成果库 -->
            <%@ include file="/WEB-INF/pages/admin/divs/achievementListDiv.jsp" %>

            <%
                if (staff.getType() == 1) {
            %>
            <!--姻缘簿-->
            <%@ include file="/WEB-INF/pages/admin/divs/matchingDiv.jsp" %>
            <%
                }
            %>

            <% if (staff.getType() == 0) {%>
            <!--礼物管理-->
            <%@include file="/WEB-INF/pages/admin/divs/giftManageDiv.jsp" %>
            <%}%>

            <!--活动管理-->
            <%@include file="/WEB-INF/pages/admin/divs/activityManage.jsp" %>

        </div>
    </div>
</div>
</body>
</html>